xquery version "1.0";

<results>
{     
    for $contactInfo in
        doc("contactinfo.xml")
        //row
       
    let 
        $email := $contactInfo/email
        
    where
        $email = "guptasameer09@yahoo.com"
  
    return
        <id_email>
        { 
            ($contactInfo/emp_no, $email)
        }        
        </id_email>
}
</results>